--- i3-4.18.3/include/libi3.h	2020-10-20 17:06:25.000000000 +0900
+++ i3-4.18.3.patched/include/libi3.h	2021-01-09 16:11:52.571112045 +0900
@@ -341,7 +341,7 @@
  */
 uint32_t get_colorpixel(const char *hex) __attribute__((const));
 
-#ifndef HAVE_strndup
+#ifndef HAVE_STRNDUP
 /**
  * Taken from FreeBSD
  * Returns a pointer to a new string which is a duplicate of the
diff --color -ruN i3-4.18.3/libi3/strndup.c i3-4.18.3.patched/libi3/strndup.c
--- i3-4.18.3/libi3/strndup.c	2020-10-20 17:06:25.000000000 +0900
+++ i3-4.18.3.patched/libi3/strndup.c	2021-01-09 16:12:46.972114812 +0900
@@ -10,7 +10,7 @@
 #include <sys/types.h>
 #include <string.h>
 
-#ifndef HAVE_strndup
+#ifndef HAVE_STRNDUP
 /*
  * Taken from FreeBSD
  * Returns a pointer to a new string which is a duplicate of the
